package edu.avans.hartigehap.domain;

import edu.avans.hartigehap.domain.Order.OrderStatus;

public class SubmittedState implements State
{
	private Order order;
	
	public SubmittedState(Order order)
	{
		this.order = order;
	}
	
	@Override
	public void fill()  throws StateException 
	{
		throw new StateException("Cannot fill an order that is already submitted");
	}
	
	@Override
	public void empty()  throws StateException 
	{
		throw new StateException("Cannot empty an order that is already submitted");
	}
	
	@Override
	public void submit()  throws StateException 
	{
		throw new StateException("Order is already submitted");
	}
}